"Include aSemObj into the library for future reuse. Shan August 26,
1989"
| name pastePt choice |
pastePt _ self eventQueue mousePoint - 20.
self eventQueue disable.
choice _ BinaryChoice message: 'Do you really want to promote this\ Interaction Technique into the library?' withCRs.
self eventQueue enable.
choice ifFalse: [^nil].
name _ nil.
[name isNil]
whileTrue:
[self eventQueue disable.
name _ FillInTheBlank request: 'Please enter the name of this library object.'.
self eventQueue enable.
name = '' ifTrue: [^nil].
(ITStore includesKey: name)
ifTrue:
[name _ nil.
self notify: 'This name has been used in the library. \ Either choose another name or remove the old one first.' withCRs]]. "Make a LibraryObject to represent it at where the mouse pt."
self
promote: aSemObj
withName: name
at: pastePt!
promote: aSemObj withName: name at: pastePt
"No question asked. Shan November 17, 1989"
| prototype libObj |
Cursor wait
showWhile:
[prototype _ aSemObj duplicate.
"This is not necessary. The duplicate method should handle it.
"This is a text script of the demo. Follow this script to demo the
ModeComposer. Shan September 21, 1989"
"
SHOW THE SUN'S PERFMETER.
DeskCal
1. Get a background and paste
TextLabel (don't change text)
3 TextButtons (0,1,C)
Push one button
2. Ask what this is.
Give hints
Change text to 908876512
Add a 'Sharp' logo
3. Create ApplObj and connect 0 and
1 button with it. Connect it to
displayArea.
4. Change ApplObj to include memory
5. Add C button
6. Hide connection and promote it.
7. Put it into a window
Self Building
1. Ctrl-E the close box and show
connections
2. Recursively Show-SemObj on
applObj (and demo the bitEdit
on superman logo)
3. Change two scrollbar to one roam
box for the ITLib
move a libObj to far corner
Remove one scrollbar
Change the size of the other
Change its resize constraint
4. Move the roam box out of the Lib.
show the connection.
Window (Pane) in Window
1. Create root window and appl mode.
2. Add 2 window to it.
3. Add a DeskCal under the windows.
4. Add scroll bar.
5. Promote the whole application.
Create OddShape window
1. Use a FixedImage mode.
2. Form edit. (drill a rectangle hole in the shape).
3. Edit the figure.
4. Use MoveImageController1.
Build Window
1. TitleBar move it to the bottom to make it wierd.
2. Resize box on topRight. Use fixedImage mode. Fix the constraints.
3. Appl mode in the middle (use 'stickFourCorners').
4. Horizontal ScrollBar to the left.
5. Put a ordinary window in it. Change ApplMode to 'matchViewportWindow'.
6. Promote it.
*. Close box is a problem. When closed, we lose the window.
*. Show a window with vertical titlebar.
Two V ScrollBars for One
1. one vertical one horizontal
2. change one to vertical but longer
Build ScrollBar
1. My scrollbar
The link from roam box to marker needs special technique. Occupy the target1 of roam box first, then try to link to marker. System will ask a new inst var.
2. The Sml scrollbar
"!
modeComposingTest
"Shan July 31, 1989"
"LibrarySpace modeComposingTest"
| rMode w applCreator |
rMode _ RootMode new.
rMode label: 'MMS Mode Composer'.
rMode minimumSize: 900 @ 730.
w _ Window
title: ' I T Library'
origin: 450 @ 30
extent: 400 @ 400.
w titleBar: ShadedTitleBar new.
w shrinkPosition: 700 @ 50.
w initialOpen.
w applicationMode: (LibrarySpace new mode insideColor: Form white).
w addVerticalScrollBar.
w addHorizontalScrollBar.
w attachModeTo: rMode.
applCreator _ ApplObjCreator new.
applCreator attachModeTo: rMode at: 750@450.
rMode startUp! !
!LibrarySpace class methodsFor: 'IT store access'!